import type { App } from 'vue'

import {
  Tab,
  Tabs,
  Icon,
  Uploader,
  Toast,
  Field,
  Popup,
  DatePicker,
  Picker,
  Overlay,
  Button,
  RadioGroup,
  Radio,
  Checkbox,
  CheckboxGroup,
  Form,
  Search,
  Calendar,
  Notify
} from 'vant'

const components = [
    Tab,
    Tabs,
    Icon,
    Uploader,
    Toast,
    Field,
    Popup,
    DatePicker,
    Picker,
    Overlay,
    Button,
    RadioGroup,
    Radio,
    Checkbox,
    CheckboxGroup,
    Form,
    Search,
    Calendar,
    Notify]

export function setVantUi(app: App<Element>) {
    components.map(item => {
        app.use(item)
    })
}
